public class AtomicityVoilation {
	
	public static boolean flag = true;
	
	public static boolean finalState;
	
	public static void main(String[] args){
		new Process().start(); 
		if(flag){
			finalState=flag;
		}   
	}
}

class Process extends Thread{
	public void run(){
		AtomicityVoilation.flag = false;
	}
}
 